<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Class template char_decorator_terminal</title>
<link rel="stylesheet" href="../../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../index.html" title="Chapter 1. Boost.Log v2">
<link rel="up" href="../../../expressions.html#header.boost.log.expressions.formatters.char_decorator_hpp" title="Header &lt;boost/log/expressions/formatters/char_decorator.hpp&gt;">
<link rel="prev" href="char_decorator_actor.html" title="Class template char_decorator_actor">
<link rel="next" href="pattern_replacer.html" title="Class template pattern_replacer">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr><td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../boost.png"></td></tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="char_decorator_actor.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../expressions.html#header.boost.log.expressions.formatters.char_decorator_hpp"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="pattern_replacer.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.log.expressions.char_decorator_terminal"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Class template char_decorator_terminal</span></h2>
<p>boost::log::expressions::char_decorator_terminal</p>
</div>
<h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2>
<div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../../expressions.html#header.boost.log.expressions.formatters.char_decorator_hpp" title="Header &lt;boost/log/expressions/formatters/char_decorator.hpp&gt;">boost/log/expressions/formatters/char_decorator.hpp</a>&gt;

</span><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> SubactorT<span class="special">,</span> <span class="keyword">typename</span> ImplT<span class="special">&gt;</span> 
<span class="keyword">class</span> <a class="link" href="char_decorator_terminal.html" title="Class template char_decorator_terminal">char_decorator_terminal</a> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
  <span class="comment">// types</span>
  <span class="keyword">typedef</span> <span class="identifier">ImplT</span>                                 <a name="boost.log.expressions.char_decorator_terminal.impl_type"></a><span class="identifier">impl_type</span><span class="special">;</span>      <span class="comment">// Implementation type. </span>
  <span class="keyword">typedef</span> <span class="identifier">impl_type</span><span class="special">::</span><span class="identifier">char_type</span>                  <a name="boost.log.expressions.char_decorator_terminal.char_type"></a><span class="identifier">char_type</span><span class="special">;</span>      <span class="comment">// Character type. </span>
  <span class="keyword">typedef</span> <span class="identifier">impl_type</span><span class="special">::</span><span class="identifier">string_type</span>                <a name="boost.log.expressions.char_decorator_terminal.string_type"></a><span class="identifier">string_type</span><span class="special">;</span>    <span class="comment">// String type. </span>
  <span class="keyword">typedef</span> <span class="identifier">basic_formatting_ostream</span><span class="special">&lt;</span> <span class="identifier">char_type</span> <span class="special">&gt;</span> <a name="boost.log.expressions.char_decorator_terminal.stream_type"></a><span class="identifier">stream_type</span><span class="special">;</span>    <span class="comment">// Stream type. </span>
  <span class="keyword">typedef</span> <span class="identifier">SubactorT</span>                             <a name="boost.log.expressions.char_decorator_terminal.subactor_type"></a><span class="identifier">subactor_type</span><span class="special">;</span>  <span class="comment">// Adopted actor type. </span>
  <span class="keyword">typedef</span> <span class="identifier">string_type</span>                           <a name="boost.log.expressions.char_decorator_terminal.result_type"></a><span class="identifier">result_type</span><span class="special">;</span>    <span class="comment">// Result type definition. </span>

  <span class="comment">// <a class="link" href="char_decorator_terminal.html#boost.log.expressions.char_decorator_terminalconstruct-copy-destruct">construct/copy/destruct</a></span>
  <a class="link" href="char_decorator_terminal.html#idm27498-bb"><span class="identifier">char_decorator_terminal</span></a><span class="special">(</span><span class="identifier">subactor_type</span> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">impl_type</span> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="char_decorator_terminal.html#idm27505-bb"><span class="identifier">char_decorator_terminal</span></a><span class="special">(</span><a class="link" href="char_decorator_terminal.html" title="Class template char_decorator_terminal">char_decorator_terminal</a> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="char_decorator_terminal.html#idm27511-bb"><span class="identifier">char_decorator_terminal</span></a><span class="special">(</span><span class="special">)</span> <span class="special">=</span> <span class="keyword">delete</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="char_decorator_terminal.html#idm27469-bb">public member functions</a></span>
  <span class="identifier">subactor_type</span> <span class="keyword">const</span>  <span class="special">&amp;</span> <a class="link" href="char_decorator_terminal.html#idm27470-bb"><span class="identifier">get_subactor</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">impl_type</span> <span class="keyword">const</span>  <span class="special">&amp;</span> <a class="link" href="char_decorator_terminal.html#idm27476-bb"><span class="identifier">get_impl</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> ContextT<span class="special">&gt;</span> <span class="identifier">result_type</span> <a class="link" href="char_decorator_terminal.html#idm27482-bb"><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span></a><span class="special">(</span><span class="identifier">ContextT</span> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> ContextT<span class="special">&gt;</span> <span class="identifier">result_type</span> <a class="link" href="char_decorator_terminal.html#idm27490-bb"><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span></a><span class="special">(</span><span class="identifier">ContextT</span> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idm42533"></a><h2>Description</h2>
<p>Character decorator terminal class. This formatter allows to modify strings generated by other formatters on character level. The most obvious application of decorators is replacing a certain set of characters with decorated equivalents to satisfy requirements of text-based sinks.</p>
<p>The <code class="computeroutput"><a class="link" href="char_decorator_terminal.html" title="Class template char_decorator_terminal">char_decorator_terminal</a></code> class aggregates the formatter being decorated, and a set of string pairs that are used as decorations. All decorations are applied sequentially. The <code class="computeroutput"><a class="link" href="char_decorator_terminal.html" title="Class template char_decorator_terminal">char_decorator_terminal</a></code> class is a formatter itself, so it can be used to construct more complex formatters, including nesting decorators. </p>
<div class="refsect2">
<a name="idm42541"></a><h3>
<a name="boost.log.expressions.char_decorator_terminalconstruct-copy-destruct"></a><code class="computeroutput">char_decorator_terminal</code> 
        public
       construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><a name="idm27498-bb"></a><span class="identifier">char_decorator_terminal</span><span class="special">(</span><span class="identifier">subactor_type</span> <span class="keyword">const</span> <span class="special">&amp;</span> sub<span class="special">,</span> <span class="identifier">impl_type</span> <span class="keyword">const</span> <span class="special">&amp;</span> impl<span class="special">)</span><span class="special">;</span></pre>
<p>Initializing constructor. </p>
</li>
<li class="listitem">
<pre class="literallayout"><a name="idm27505-bb"></a><span class="identifier">char_decorator_terminal</span><span class="special">(</span><a class="link" href="char_decorator_terminal.html" title="Class template char_decorator_terminal">char_decorator_terminal</a> <span class="keyword">const</span> <span class="special">&amp;</span> that<span class="special">)</span><span class="special">;</span></pre>
<p>Copy constructor </p>
</li>
<li class="listitem"><pre class="literallayout"><a name="idm27511-bb"></a><span class="identifier">char_decorator_terminal</span><span class="special">(</span><span class="special">)</span> <span class="special">=</span> <span class="keyword">delete</span><span class="special">;</span></pre></li>
</ol></div>
</div>
<div class="refsect2">
<a name="idm42584"></a><h3>
<a name="idm27469-bb"></a><code class="computeroutput">char_decorator_terminal</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="identifier">subactor_type</span> <span class="keyword">const</span>  <span class="special">&amp;</span> <a name="idm27470-bb"></a><span class="identifier">get_subactor</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>
</p>
<div class="variablelist"><table border="0" class="variablelist compact">
<colgroup>
<col align="left" valign="top">
<col>
</colgroup>
<tbody><tr>
<td><p><span class="term">Returns:</span></p></td>
<td><p>Adopted subactor </p></td>
</tr></tbody>
</table></div>
</li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">impl_type</span> <span class="keyword">const</span>  <span class="special">&amp;</span> <a name="idm27476-bb"></a><span class="identifier">get_impl</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>
</p>
<div class="variablelist"><table border="0" class="variablelist compact">
<colgroup>
<col align="left" valign="top">
<col>
</colgroup>
<tbody><tr>
<td><p><span class="term">Returns:</span></p></td>
<td><p>Implementation </p></td>
</tr></tbody>
</table></div>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> ContextT<span class="special">&gt;</span> <span class="identifier">result_type</span> <a name="idm27482-bb"></a><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span><span class="special">(</span><span class="identifier">ContextT</span> <span class="keyword">const</span> <span class="special">&amp;</span> ctx<span class="special">)</span><span class="special">;</span></pre>
<p>Invokation operator </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> ContextT<span class="special">&gt;</span> <span class="identifier">result_type</span> <a name="idm27490-bb"></a><span class="keyword">operator</span><span class="special">(</span><span class="special">)</span><span class="special">(</span><span class="identifier">ContextT</span> <span class="keyword">const</span> <span class="special">&amp;</span> ctx<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>Invokation operator </p>
</li>
</ol></div>
</div>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2007-2021 Andrey Semashev<p>
        Distributed under the Boost Software License, Version 1.0. (See accompanying
        file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>).
      </p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="char_decorator_actor.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../expressions.html#header.boost.log.expressions.formatters.char_decorator_hpp"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="pattern_replacer.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
